package com.qing.design.patterns.facade.example.some_complex_media_library;

public class CodecFactory {
	/**
	 * 摘录
	 * @return
	 */
	public static Codec extract(VideoFile file){
		String type=file.getCodecType();
		if(type.equals("map4")){
			return new MPEG4CompressionCodec();
		}else{
			return new OggCompressionCodec();
		}
	}

}
